{extend name="base" /} {block name="body"}
<div class="layui-body">
    <!--tab标签-->
    <div class="layui-tab layui-tab-brief">
        <ul class="layui-tab-title">
            <li class="">
                <a href="{:url('admin/images/index')}">图片管理</a>
            </li>
            <li class="layui-this">编辑图片</li>
        </ul>
        <div class="layui-tab-content">
            <div class="layui-tab-item layui-show">
                <form class="layui-form form-container" action="{:url('admin/images/update',['id'=>$img_info['id']])}" method="post">
                    <div class="layui-form-item">
                        <label class="layui-form-label">所属栏目</label>
                        <div class="layui-input-block">
                            <select name="pid" lay-verify="required">
                                {foreach name="imgcategory_level_list" item="vo"}
                                <option {eq name="$img_info.pid" value="$vo.id" }selected{/eq} value="{$vo.id}">{neq name="vo.level" value="1"}|{php}for($i=1;$i
                                    <$vo[ 'level'];$i++){echo ' ----';}{/php}{/neq}
                                        {$vo.name}</option>
                                        {/foreach}
                            </select>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">标题</label>
                        <div class="layui-input-block">
                            <input type="text" name="title" value="{$img_info.title}" style="width:50%;" class="layui-input">
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">图片</label>
                        <div class="layui-input-block">
                            <input type="text" name="thumb" value="{$img_info.path}" class="layui-input layui-input-inline" id="thumb">
                            <input type="file" name="file" class="layui-upload-file">
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">类型</label>
                        <div class="layui-input-block">
                            {foreach name=":config('type')" item="v"}
                            <input type="radio" name="type" value="{$v.value}" title="{$v.name}" {eq name="$img_info.type" value="$v.value" }checked{/eq}> {/foreach}
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-input-block">
                            <button class="layui-btn" lay-submit lay-filter="*">保存</button>
                            <button type="reset" class="layui-btn layui-btn-primary">重置</button>
                        </div>
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>
{/block} {block name="js"}
<script src="__JS__/kindeditor/kindeditor.config.js"></script>
<script src="__JS__/kindeditor/kindeditor-all-min.js"></script> {/block}